Data Services Developer's Guide : Create Your First Data Services Model
This page last changed on Jan 09, 2008 by tkatz.
eDocs Home > BEA AquaLogic Data Services Platform 3.0 Documentation > Data Services Developer's Guide
|
![]() | For more information on data service modeling concepts see Modeling and a Service-Oriented Architecture in the ALDSP 2.5 Concepts Guide. |
You can create a sample data service relationship model by selecting a dataspace project and choosing:
File > New > Relationship Modeler
You can locate your model diagram anywhere in your project. Any legal filename can be used.
This example assumes that you are using the ALDSP RTLApp as a data source.
The physical data services used in this sample are:
![]() | Creating and Updating Physical Data Services |
You can add data services to your model using simple drag-and-drop from the Project Explorer. In the Project Explorer you can multi-select data services using either:
If you drag a set of data services into a model diagram, existing relationships to other data services in the model will be shown.
Since the data services in this example are representations of relational sources, a several bidirectional relationships between CUSTOMER_ORDER and CUSTOMER_ORDER_LINE_ITEMS were inferred:
A next step could be to create a relationship between CUSTOMER and CUSTOMER_ORDER.
The Relationship Properties wizard appears.
Relationship properties can be uni- or bi-directional.
Option | Action |
Comment/Reference |
---|---|---|
Set directionality |
Select the directions to be supported in the relationship. The example is bidirectional so the default checked condition for the following relationships need not be changed:
|
Creating relationships in a model automatically creates relationship functions between data services. Bi-directional settings mean that "get" functions for the related data service will be created on both sides of the relationship. By default, relationships are bidirectional. |
Target Role Name |
Enter the name of the role function. In the example, default names can be used:
|
By default the name will be based on the name of the related data service. It can be changed to any unique and legal name in your dataspace project. |
Set maximum and minimum occurances | Enter cardinality settings for the respective function. For the example the following settings are used:
|
The minimum and maximum occurrence settings definite the nature of the relationship between the two services. |
Click Next.
Each navigation function (one or two) being created also needs to be configured. Configuration includes:
Element | Purpose | ||
---|---|---|---|
Navigation function name | By default, the navigation function name is the name of the target data service with "get" prepended, as in "getCustomer". If a function of that name exists, numbers will be appended to the function name as in getCustomer1.
|
||
Related data service function | By default, the root function in the target data service is selected. However, you can select any available read function in the target data service. | ||
Map input parameters | If the related function has input parameters, the name and type of the available parameters appear. You can then use a pulldown menu to select an element from the target data service to map as the input parameter. | ||
Build WHERE clause | Where clauses can be added to the function using pulldown menus that allow you to select join elements from each side of the relationship. | ||
Add or Remove | Allows you to add additional where clauses or delete an identified where clause. | ||
Next | When the relationship between data services is bidirectional clicking Next changes the focus to the second data service, where you can identify a navigation function name, parameters, and add where clauses for the second side of the relationship. |
![]() |
Document generated by Confluence on Jan 15, 2008 11:02 |